package org.jsola.hr.web;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.jsola.core.Page;
import org.jsola.core.Result;
import org.jsola.hr.dto.EmpSocBackRecordInfoAddDTO;
import org.jsola.hr.dto.EmpSocBackRecordInfoUpdateDTO;
import org.jsola.hr.query.EmpSocBackRecordInfoQuery;
import org.jsola.hr.vo.EmpSocBackRecordInfoListVO;
import org.jsola.hr.vo.EmpSocBackRecordInfoVO;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestBody;

import javax.validation.Valid;
import java.util.List;

/**
 * 社保回款信息
 *
 * @author zhr
 */
@Api(tags = "hr-社保回款信息")
public interface IEmpSocBackRecordInfoControllerAPI {

    /**
     * 新增社保回款信息
     *
     * @param empSocBackRecordInfoAddDTO 社保回款信息新增实体
     * @return 社保回款信息展示对象
     */
    @ApiOperation(value = "新增社保回款信息")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoAddDTO", dataType = "EmpSocBackRecordInfoAddDTO", value = "新增社保回款信息", paramType = "body")
    })
    Result<EmpSocBackRecordInfoVO> save(EmpSocBackRecordInfoAddDTO empSocBackRecordInfoAddDTO);

    /**
     * 新增社保回款信息(批量)
     *
     * @param empSocBackRecordInfos 社保回款信息新增实体
     * @return 新增数量
     */
    @ApiOperation(value = "新增社保回款信息(批量)")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoAddDTO", dataType = "EmpSocBackRecordInfoAddDTO[]",
                    value = "新增社保回款信息", paramType = "body", allowMultiple = true)
    })
    Result<Integer> saveBatch(EmpSocBackRecordInfoAddDTO[] empSocBackRecordInfos);


    /**
     * 修改社保回款信息
     *
     * @param empSocBackRecordInfoUpdateDTO 社保回款信息
     * @return 更新数量
     */
    @ApiOperation(value = "修改社保回款信息")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoUpdateDTO", dataType = "EmpSocBackRecordInfoUpdateDTO", value = "修改社保回款信息", paramType = "body")
    })
    Result<Integer> update(EmpSocBackRecordInfoUpdateDTO empSocBackRecordInfoUpdateDTO);


    /**
     * 删除单个社保回款信息，彻底删除
     *
     * @param empSocBackRecordInfoId 社保回款信息id
     * @return 删除数量
     */
    @ApiOperation(value = "删除单个社保回款信息，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoId", dataType = "String", value = "社保回款信息id", paramType = "path")
    })
    Result<Integer> delete(String empSocBackRecordInfoId);


    /**
     * 批量删除社保回款信息，彻底删除
     *
     * @param empSocBackRecordInfoIds 社保回款信息id集合
     * @return 删除数量
     */
    @ApiOperation(value = "批量删除社保回款信息，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoIds", dataType = "String[]", value = "社保回款信息id数组", paramType = "body", allowMultiple = true)
    })
    Result<Integer> deleteBatch(String[] empSocBackRecordInfoIds);


    /**
     * 根据社保回款信息id查询社保回款信息详情
     *
     * @param empSocBackRecordInfoId 社保回款信息id
     * @return 社保回款信息详情
     */
    @ApiOperation(value = "根据社保回款信息id查询社保回款信息详情")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoId", dataType = "String", value = "社保回款信息id", paramType = "path")
    })
    Result<EmpSocBackRecordInfoVO> findById(String empSocBackRecordInfoId);


    /**
     * 查询社保回款信息
     *
     * @param empSocBackRecordInfoQuery 社保回款信息查询参数
     * @return page
     */
    @ApiOperation(value = "查询社保回款信息")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoQuery", dataType = "EmpSocBackRecordInfoQuery", value = "社保回款信息查询参数", paramType = "query")
    })
    Result<List<EmpSocBackRecordInfoListVO>> listAll(EmpSocBackRecordInfoQuery empSocBackRecordInfoQuery);


    /**
     * 分页查询社保回款信息
     *
     * @param empSocBackRecordInfoQuery 社保回款信息查询参数
     * @return page
     */
    @ApiOperation(value = "分页查询社保回款信息")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoQuery", dataType = "EmpSocBackRecordInfoQuery", value = "社保回款信息查询参数", paramType = "query")
    })
    Result<Page<EmpSocBackRecordInfoListVO>> page(EmpSocBackRecordInfoQuery empSocBackRecordInfoQuery);

    /**
     * 分页查询社保回款信息(POST)
     *
     * @param empSocBackRecordInfoQuery 社保回款信息查询参数
     * @return page
     */
    @ApiOperation(value = "分页查询社保回款信息(POST)")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "empSocBackRecordInfoQuery", dataType = "EmpSocBackRecordInfoQuery", value = "社保回款信息查询参数", paramType = "body")
    })
    Result<Page<EmpSocBackRecordInfoListVO>> pagePost(EmpSocBackRecordInfoQuery empSocBackRecordInfoQuery);

    /**
     * 导出社保回款记录
     *
     * @param query 参数
     * @return Excel
     */
    @ApiOperation(value = "导出社保回款记录")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "query", dataType = "EmpSocBackRecordInfoQuery", value = "查询参数", paramType = "body")
    })
    ResponseEntity<Resource> exportRecordInfo(@RequestBody @Valid EmpSocBackRecordInfoQuery query);


}

